import Vue from 'vue'
import App from './App.vue'
import router from './router'
import store from './store/index'
import * as http from '@/utils/http'
import SvgIcon from '@/components/SvgIcon' // svg组件

import './assets/reset.css'
import './assets/common.css'

Vue.config.productionTip = false

// 注册到全局
Vue.component('svg-icon', SvgIcon)

Vue.prototype.$http = http


new Vue({
  router,
  store,

  render: h => h(App)
}).$mount('#app')


// 处理 svg
const requireAll = requireContext => requireContext.keys().map(requireContext)
const req = require.context('./assets/svgIcons', false, /\.svg$/)
requireAll(req)




